<template xmlns="">
  <div id="app">
    <!-- 头部区域 -->
    <div style="height: 60px; line-height: 60px; background-color: white; margin-bottom: 2px">
      <!-- 修改为更明确的路径引用方式 -->
      <img src="@/assets/logo.png" alt="logo" style="width: 40px; position: relative; top: 10px; left: 20px">
      <span style="margin-left: 25px; font-size: 24px">家谱管理系统</span>
    </div>
    <!-- 侧边栏和主体 -->
    <div style="display: flex">
      <!-- 侧边栏导航 -->
      <div style="width: 200px; min-height: calc(100vh - 62px); overflow:hidden; margin-right: 2px; background-color: white">
        <el-menu :default-active="$route.path" :default-opends="['1']" router  class="el-menu-demo">
          <el-menu-item index="/">
            <i class="el-icon-discount"></i>
            <span>首页</span>
          </el-menu-item>
          <el-submenu index="1">
            <template slot="title">
              <i class="el-icon-user-solid"></i>
              <span>用户表</span>
            </template>
            <el-menu-item index="/about">用户详情</el-menu-item>
            </el-submenu>
          <el-submenu>
            <template slot="title">
              <i class="el-icon-postcard"></i>
              <span>家谱表</span>
            </template>
            <el-menu-item index="/about">家谱详情</el-menu-item>
            <el-menu-item index="/about">家谱人员</el-menu-item>
          </el-submenu>
        </el-menu>
      </div>
      <!-- 主体数据 -->
      <div style="flex: 1;background-color: white">
        <router-view/>
      </div>
    </div>
  </div>
</template>
<script lang="ts">
</script>